//    Copyright (C) Kherty.  All rights reserved.
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using OpenLS.Chart.UI.Internals;


namespace OpenLS.Chart.UI
{
    ///<summary>
    /// Class that provides dependency properties related to chart axes
    ///</summary>
    public sealed class AxisElement: DependencyObject
    {


        public static AxisInfo GetAxisInfo(DependencyObject obj)
        {
            return (AxisInfo)obj.GetValue(AxisInfoProperty);
        }

        public static void SetAxisInfo(DependencyObject obj, AxisInfo value)
        {
            obj.SetValue(AxisInfoProperty, value);
        }

        // Using a DependencyProperty as the backing store for AxisInfo.  This enables animation, styling, binding, etc...
        public static readonly DependencyProperty AxisInfoProperty =
            DependencyProperty.RegisterAttached("AxisInfo", typeof(AxisInfo), typeof(AxisElement), new FrameworkPropertyMetadata(null, FrameworkPropertyMetadataOptions.Inherits));



        public static Orientation GetOrientation(DependencyObject obj)
        {
            return (Orientation)obj.GetValue(OrientationProperty);
            
        }

        public static void SetOrientation(DependencyObject obj, Orientation value)
        {
            obj.SetValue(OrientationProperty, value);
        }

        // Using a DependencyProperty as the backing store for Orientation.  This enables animation, styling, binding, etc...
        public static readonly DependencyProperty OrientationProperty =
            DependencyProperty.RegisterAttached("Orientation", typeof(Orientation), typeof(AxisElement), new FrameworkPropertyMetadata(Orientation.Horizontal, FrameworkPropertyMetadataOptions.Inherits));


        public static AxisPosition GetAxisPosition(DependencyObject obj)
        {
            return (AxisPosition)obj.GetValue(AxisPositionProperty);
        }

        public static void SetAxisPosition(DependencyObject obj, AxisPosition value)
        {
            obj.SetValue(AxisPositionProperty, value);
        }

        // Using a DependencyProperty as the backing store for AxisPosition.  This enables animation, styling, binding, etc...
        public static readonly DependencyProperty AxisPositionProperty =
            DependencyProperty.RegisterAttached("AxisPosition", typeof(AxisPosition), typeof(AxisElement), new FrameworkPropertyMetadata(AxisPosition.Left, FrameworkPropertyMetadataOptions.Inherits));



        public static object    GetItemsSource (DependencyObject obj)
        {
            return obj.GetValue(ItemsSourceProperty);
        }

        public static void SetItemsSource(DependencyObject obj, object value)
        {
            obj.SetValue(ItemsSourceProperty, value);
        }

        // Using a DependencyProperty as the backing store for ItemsSource.  This enables animation, styling, binding, etc...
        public static readonly DependencyProperty ItemsSourceProperty =
            DependencyProperty.RegisterAttached("ItemsSource", typeof(object), typeof(AxisElement), new FrameworkPropertyMetadata(null, FrameworkPropertyMetadataOptions.Inherits));



        public static TickLabelPosition GetTickLabelPosition(DependencyObject obj)
        {
            return (TickLabelPosition)obj.GetValue(TickLabelPositionProperty);
        }

        public static void SetTickLabelPosition(DependencyObject obj, TickLabelPosition value)
        {
            obj.SetValue(TickLabelPositionProperty, value);
        }

        // Using a DependencyProperty as the backing store for TickLabelPosition.  This enables animation, styling, binding, etc...
        public static readonly DependencyProperty TickLabelPositionProperty =
            DependencyProperty.RegisterAttached("TickLabelPosition", typeof(TickLabelPosition), typeof(AxisElement), new FrameworkPropertyMetadata(TickLabelPosition.NextTo, FrameworkPropertyMetadataOptions.Inherits));


        // Using a DependencyProperty as the backing store for Unit.  This enables animation, styling, binding, etc...


        public static Axis GetAxis(DependencyObject obj)
        {
            return (Axis)obj.GetValue(AxisProperty);
        }

        public static void SetAxis(DependencyObject obj, Axis value)
        {
            obj.SetValue(AxisProperty, value);
        }

        // Using a DependencyProperty as the backing store for Axis.  This enables animation, styling, binding, etc...
        public static readonly DependencyProperty AxisProperty =
            DependencyProperty.RegisterAttached("Axis", typeof(Axis), typeof(AxisElement), new FrameworkPropertyMetadata(null, FrameworkPropertyMetadataOptions.Inherits));


        public static TickMark GetTickMark(DependencyObject obj)
        {
            return (TickMark)obj.GetValue(TickMarkProperty);
        }

        public static void SetTickMark(DependencyObject obj, TickMark value)
        {
            obj.SetValue(TickMarkProperty, value);
        }

        // Using a DependencyProperty as the backing store for TickMark.  This enables animation, styling, binding, etc...
        public static readonly DependencyProperty TickMarkProperty =
            DependencyProperty.RegisterAttached("TickMark", typeof(TickMark), typeof(AxisElement), new FrameworkPropertyMetadata(TickMark.None, FrameworkPropertyMetadataOptions.Inherits));



        public static AxisOrientation GetAxisOrientation(DependencyObject obj)
        {
            return (AxisOrientation)obj.GetValue(AxisOrientationProperty);
        }

        public static void SetAxisOrientation(DependencyObject obj, AxisOrientation value)
        {
            obj.SetValue(AxisOrientationProperty, value);
        }

        // Using a DependencyProperty as the backing store for AxisOrientation.  This enables animation, styling, binding, etc...
        public static readonly DependencyProperty AxisOrientationProperty =
            DependencyProperty.RegisterAttached("AxisOrientation", typeof(AxisOrientation), typeof(AxisElement), new FrameworkPropertyMetadata(AxisOrientation.MinimumToMaximum, FrameworkPropertyMetadataOptions.Inherits));



        public static double GetMajorStep(DependencyObject obj)
        {
            return (double)obj.GetValue(MajorStepProperty);
        }

        public static void SetMajorStep(DependencyObject obj, double value)
        {
            obj.SetValue(MajorStepProperty, value);
        }

        // Using a DependencyProperty as the backing store for MajorStep.  This enables animation, styling, binding, etc...
        public static readonly DependencyProperty MajorStepProperty =
            DependencyProperty.RegisterAttached("MajorStep", typeof(double), typeof(AxisElement), new FrameworkPropertyMetadata(1.0, FrameworkPropertyMetadataOptions.Inherits));


        public static double GetMinorStep(DependencyObject obj)
        {
            return (double)obj.GetValue(MinorStepProperty);
        }

        public static void SetMinorStep(DependencyObject obj, double value)
        {
            obj.SetValue(MinorStepProperty, value);
        }

        // Using a DependencyProperty as the backing store for MajorStep.  This enables animation, styling, binding, etc...
        public static readonly DependencyProperty MinorStepProperty =
            DependencyProperty.RegisterAttached("MinorStep", typeof(double), typeof(AxisElement), new FrameworkPropertyMetadata(1.0, FrameworkPropertyMetadataOptions.Inherits));


        public static double GetMinimum(DependencyObject obj)
        {
            return (double)obj.GetValue(MinimumProperty);
        }

        public static void SetMinimum(DependencyObject obj, double value)
        {
            obj.SetValue(MinimumProperty, value);
        }

        // Using a DependencyProperty as the backing store for Minimum.  This enables animation, styling, binding, etc...
        public static readonly DependencyProperty MinimumProperty =
            DependencyProperty.RegisterAttached("Minimum", typeof(double), typeof(AxisElement), new FrameworkPropertyMetadata(0.0d, FrameworkPropertyMetadataOptions.Inherits));




      


        public static double GetMaximum(DependencyObject obj)
        {
            return (double)obj.GetValue(MaximumProperty);
        }

        public static void SetMaximum(DependencyObject obj, double value)
        {
            obj.SetValue(MaximumProperty, value);
        }

        // Using a DependencyProperty as the backing store for Maximum.  This enables animation, styling, binding, etc...
        public static readonly DependencyProperty MaximumProperty =
            DependencyProperty.RegisterAttached("Maximum", typeof(double), typeof(AxisElement), new FrameworkPropertyMetadata(0.0d, FrameworkPropertyMetadataOptions.Inherits));

	
    }
}
